All credit for Qualys baron samedit sudo heap overflow (https://www.qualys.com/2021/01/26/cve-2021-3156/baron-samedit-heap-based-overflow-sudo.txt).
The exploit is only for test purpose
sudo version: 1.8.31
Glibc version: 2.23
ASLR is off
https://www.qualys.com/2021/01/26/cve-2021-3156/baron-samedit-heap-based-overflow-sudo.txt
https://www.kalmarunionen.dk/writeups/sudo/
https://github.com/worawit/CVE-2021-3156